package JavaPractice;//test if git works// yes it works


public class Hourglass {
    
public static final int HOURGLASS_HEIGHT = 100;     //class constant
    
    public static void main (String[] args){
        DrawHGLine();   //done
        DrawTopHG();    //done
        DrawBottomHG(); //done
        DrawHGLine();   //done
        TesterMetho();  //tester
    
    }
    
   public static void TesterMetho(){
        System.out.println("+----+");
        for (int i = 1; i <= 3; i++) {
            System.out.println("\\    /");
            System.out.println("/    \\");
        }
        System.out.println("+----+");
      
   }
    public static void DrawHGLine(){
        System.out.print('+');
        for (int i = 1; i <= 6; i++){
            System.out.print('-');
            }
        System.out.print('+');
        System.out.println();
    }//End DrawHGLine()
    
    public static void DrawTopHG(){
        for (int line = 1; line <= HOURGLASS_HEIGHT; line++){
            System.out.print('|');
            for (int i = 1; i<= (line-1); i++){
                System.out.print(' ');
            }
            System.out.print('\\');
            for (int i = 1; i <= (6-2*line); i++){
                System.out.print('.');
            }
            System.out.print('/');
            for (int i = 1; i<= (line-1); i++){
                System.out.print(' ');
            }
            System.out.print('|');
            System.out.println();
        }
        
    }//End DrawTopHG()

    public static void DrawBottomHG(){
        for (int line = 1; line <= HOURGLASS_HEIGHT; line++){
            System.out.print('|');
            for (int i = 1; i<= (3-line); i++){     //prints the spaces
                System.out.print(' '); 
            }
            System.out.print('/');
            for (int i = 1; i <= (2*line-2); i++){  //prints the periods
                System.out.print('.');
            }
            System.out.print('\\');                  //prints the spaces 
            for (int i = 1; i<= (3-line); i++){
                System.out.print(' ');
            }
            System.out.print('|');
            System.out.println();                   
        }
    }//End DrawBottomHG()
    
}//End Class Hourglass
